﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="laoshi_pingfen.aspx.cs" Inherits="laoshi_pingfen" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>无标题页</title>
      <link href="../style.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">  
    <table cellspacing="0" style="width: 820px; height: 406px;margin-top:10px;">
        <tr>
            <td style="width: 100px; height: 34px; vertical-align: top;" class="font33">
              
                <table style="width: 724px">
                    <tr>
                        <td style="width: 66px">
                            <asp:Label ID="Label3" runat="server" Text="选择课程：" Width="75px"></asp:Label></td>
                        <td style="width: 190px">
                <asp:DropDownList ID="ddlKecheng" runat="server" AutoPostBack="True" DataSourceID="sdsKecheng"
                    DataTextField="name" DataValueField="id" Width="181px" AppendDataBoundItems="true" 
                                onselectedindexchanged="ddlKecheng_SelectedIndexChanged">
                    <asp:ListItem Value="-1" Text="选择课程"></asp:ListItem>
                </asp:DropDownList></td>
                        <td style="width: 70px">
                            <asp:Label ID="Label4" runat="server" Text="选择学生：" Width="78px"></asp:Label></td>
                        <td style="width: 139px" >
                            <asp:DropDownList ID="ddlXuesheng" runat="server" AutoPostBack="True" DataSourceID="sdsXuesheng"
                    DataTextField="stu_username1" DataValueField="stu_username" Width="93px" OnSelectedIndexChanged="ddlXuesheng_SelectedIndexChanged">
                            </asp:DropDownList></td>
                        <td>
                            <asp:Button ID="btn_display" runat="server" OnClick="btn_display_Click" Text="显示答案"
                                Width="81px" /></td>
                        <td>
                            <asp:Button ID="btnSubmit" runat="server" OnClick="btnSubmit_Click" Text="提交分数" Width="105px" /></td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr id="show_wenda">
            <td style="width: 100px">
                <asp:DataList ID="DataList3" runat="server" BackColor="White" BorderColor="White"
                    BorderStyle="Double" CellPadding="4" Font-Size="9pt" Width="475px" CssClass="font33">
                    <FooterStyle BackColor="White" ForeColor="#333333" />
                    <ItemStyle BackColor="White" ForeColor="#333333" />
                    <SelectedItemStyle BackColor="#339966" Font-Bold="True" ForeColor="White" />
                    <HeaderStyle BackColor="#336666" Font-Bold="True" ForeColor="White" />
                    <ItemTemplate>
                        &nbsp;<asp:Label ID="Labelwd" runat="server" Font-Size="9pt" Height="9px" Width="9px"></asp:Label><%#DataBinder.Eval(Container.DataItem, "que_subject")%>
                        (<asp:Label ID="lblWendaScore" runat="server" Text='<%# Eval("score0") %>' Width="10px"></asp:Label>
                        <asp:Label ID="Label5" runat="server" Text="分）"></asp:Label><asp:Label
                            ID="Label1" runat="server" Text="Label" Visible="False" Width="108px"></asp:Label>
                        <asp:Label ID="Label2" runat="server" Text="评分" Width="36px"></asp:Label>
                        <asp:TextBox ID="txtScire1" runat="server" Width="48px" Text="0"></asp:TextBox>
                        <asp:RangeValidator ID="RangeValidator1" runat="server" ErrorMessage="请给出合理的分数"
                            MaximumValue="100" MinimumValue="0" ControlToValidate="txtScire1" Type="Integer"></asp:RangeValidator>
                        <asp:Label ID="lblid" runat="server" Text='<%# Eval("id") %>' Visible="False"></asp:Label>
                        <table
                            style="font-size: 9pt; width: 267px">
                            <tr>
                                <td colspan="3" style="width: 700px; height: 104px">
                                    <asp:TextBox ID="txtanswer" runat="server" Text='<%# Eval("que_answer") %>' Height="129px" Width="659px" ReadOnly="True"></asp:TextBox></td>
                            </tr>
                        </table>
                    </ItemTemplate>
                </asp:DataList></td>
        </tr>
        <tr>
            <td style="width: 100px; height: 17px;">
            </td>
        </tr>
        <tr>
            <td style="width: 100px; height: 17px">
                <asp:SqlDataSource ID="sdsKecheng" runat="server" ConnectionString="<%$ ConnectionStrings:gConnectionString %>"
                    SelectCommand="SELECT [id], [name] FROM [kecheng] WHERE (([laoshi] = @laoshi) OR ([writer] = @writer)) AND ([confirm] = @confirm)">
                    <SelectParameters>
                        <asp:SessionParameter Name="laoshi" SessionField="sUserName" Type="String" />
                        <asp:SessionParameter Name="writer" SessionField="sUserName" Type="String" />
                        <asp:Parameter DefaultValue="终审通过" Name="confirm" Type="String" />
                    </SelectParameters>
                </asp:SqlDataSource>
                <asp:SqlDataSource ID="sdsXuesheng" runat="server" ConnectionString="<%$ ConnectionStrings:xxptConnectionString %>"
                    
                    SelectCommand="SELECT [stu_username1], [stu_username] FROM [tb_StuResult_wenda] WHERE ([kecheng_id] = @kecheng_id) AND [finished] = 0">
                    <SelectParameters>
                        <asp:ControlParameter ControlID="ddlKecheng" Name="kecheng_id" PropertyName="SelectedValue"
                            Type="Int64" />
                    </SelectParameters>
                </asp:SqlDataSource>
            </td>
        </tr>
</table>
</form>
</body>
</html>
